/****** Object:  Stored Procedure dbo.spr_InsertDBOrdersDetail  ******/

 use [TourIS]
 GO

 if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[spr_InsertDBOrdersDetail]') and OBJECTPROPERTY(id, N'IsProcedure') = 1)
 drop procedure [dbo].[spr_InsertDBOrdersDetail]
 GO

 SET QUOTED_IDENTIFIER OFF
 GO
 SET ANSI_NULLS OFF
 GO

 CREATE  PROCEDURE [dbo].[spr_InsertDBOrdersDetail]
 (
	@carid int,
	@carprice decimal(10,
 2),
	@clientvisaid int,
	@compid int,
	@driverid int,
	@driverprice decimal(10,
 2),
	@hotelid int,
	@hotelprice decimal(10,
 2),
	@hreservdetails varchar(50),
	@is3rdpartycar bit,
	@is3rdpartydriver bit,
	@orderid int,
	@othertransp varchar(50),
	@remarks varchar(50),
	@srno bigint,
	@transpnoofdays int,
	@transpprice int
 )
 AS

 BEGIN
	SET NOCOUNT ON
	DECLARE @Err int

	INSERT INTO [OrdersDetail]
	(
		[CarId],
		[CarPrice],
		[ClientVisaId],
		[CompId],
		[DriverId],
		[DriverPrice],
		[HotelId],
		[HotelPrice],
		[HReservDetails],
		[Is3rdPartyCar],
		[Is3rdPartyDriver],
		[OrderId],
		[OtherTransp],
		[Remarks],
		[SrNo],
		[TranspNoOfDays],
		[TranspPrice]
	)
	VALUES
	(
		@carid,
		@carprice,
		@clientvisaid,
		@compid,
		@driverid,
		@driverprice,
		@hotelid,
		@hotelprice,
		@hreservdetails,
		@is3rdpartycar,
		@is3rdpartydriver,
		@orderid,
		@othertransp,
		@remarks,
		@srno,
		@transpnoofdays,
		@transpprice
	)

	SET @Err = @@Error
	RETURN @Err
 END

 GO

 SET QUOTED_IDENTIFIER OFF
 GO
 SET ANSI_NULLS ON
 GO

